home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / asmutil / a86v400.zip / USAGE.8 < prev   
Text File  |  1990-01-25  |  690b  |  18 lines

  1. ;---------------
  2. ;   USAGE      library module, NOT a standalone program
  3. ;---------------
  4.  
  5. ; This module provides the routine USAGE_EXIT, which outputs the message
  6. ;  USAGE_MSG, of size USAGE_SIZE bytes, to the error console; then exits
  7. ;  the program with error code 1.
  8. ;
  9. ;  USAGE_MSG and USAGE_SIZE must be defined by the user's program!
  10.  
  11. USAGE_EXIT:
  12.   MOV DX,USAGE_MSG        ; point to the usage message
  13.   MOV CX,USAGE_SIZE       ; load the length of the message
  14.   CALL EWRITE             ; output the message to the error console
  15. BAD_EXIT:
  16.   MOV AL,1                ; 1 code means program was unsuccessful
  17.   JMP EXIT                ; exit back to the operating system
  18.